import Vue from 'vue'
import Vuex from 'vuex'

Vue.use(Vuex)

export default new Vuex.Store({
  state: {
    city:'郑州',
    name:'郑州',
    title:'不凡学院',
    center:[113.598609, 34.747034],
  },
  getters: {
    data(states){
      return {
        city:states.city,
        name:states.name,
        center:states.center,
        title:states.title
      }
    }
  },
  mutations: {
    uplocation(states,obj){
      states.name=obj.name
      states.title=obj.name
      states.center=[obj.location.lng,obj.location.lat];
    }
  },
  actions: {
  },
  modules: {
  }
})
